package com.drugmanage.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

public class Drug {
    /**
     * id
     * 主键
     */
    private Integer id;

    /**
     * drugName
     * 药品名称
     */
    private String drugname;

    /**
     * drugId
     * 药品编号
     */
    private Integer drugid;

    /**
     * drugType
     * 药品类型   0-中药     1-西药
     */
    private Boolean drugtype;

    /**
     * drugNum
     * 库存数量
     */
    private Integer drugnum;

    /**
     * salePrice
     * 售价
     */
    private BigDecimal saleprice;

    /**
     * buyPrice
     * 进价
     */
    private BigDecimal buyprice;

    /**
     * producerId
     * 供应商Id
     */
    private Integer producerid;

    /**
     * createDate
     *
     */
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    private Date createdate;

    /**
     * updateDate
     *
     */
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    private Date updatedate;

    /**
     * isValid
     *
     */
    private Boolean isvalid;

    private Integer guaranteePeriod;

    private String produceDateStr;

    private String drugTypeStr;

    public String getDrugTypeStr() {
        return drugTypeStr;
    }

    public void setDrugTypeStr(String drugTypeStr) {
        this.drugTypeStr = drugTypeStr;
    }

    public String getProduceDateStr() {
        return produceDateStr;
    }

    public void setProduceDateStr(String produceDateStr) {
        this.produceDateStr = produceDateStr;
    }

    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    private Date produceDate;

    private String producer;

    public String getProducer() {
        return producer;
    }

    public void setProducer(String producer) {
        this.producer = producer;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getDrugname() {
        return drugname;
    }

    public void setDrugname(String drugname) {
        this.drugname = drugname;
    }

    public Integer getDrugid() {
        return drugid;
    }

    public void setDrugid(Integer drugid) {
        this.drugid = drugid;
    }

    public Boolean getDrugtype() {
        return drugtype;
    }

    public void setDrugtype(Boolean drugtype) {
        this.drugtype = drugtype;
    }

    public Integer getDrugnum() {
        return drugnum;
    }

    public void setDrugnum(Integer drugnum) {
        this.drugnum = drugnum;
    }

    public BigDecimal getSaleprice() {
        return saleprice;
    }

    public void setSaleprice(BigDecimal saleprice) {
        this.saleprice = saleprice;
    }

    public BigDecimal getBuyprice() {
        return buyprice;
    }

    public void setBuyprice(BigDecimal buyprice) {
        this.buyprice = buyprice;
    }

    public Integer getProducerid() {
        return producerid;
    }

    public void setProducerid(Integer producerid) {
        this.producerid = producerid;
    }

    public Date getCreatedate() {
        return createdate;
    }

    public void setCreatedate(Date createdate) {
        this.createdate = createdate;
    }

    public Date getUpdatedate() {
        return updatedate;
    }

    public void setUpdatedate(Date updatedate) {
        this.updatedate = updatedate;
    }

    public Boolean getIsvalid() {
        return isvalid;
    }

    public void setIsvalid(Boolean isvalid) {
        this.isvalid = isvalid;
    }

    public Integer getGuaranteePeriod() {
        return guaranteePeriod;
    }

    public void setGuaranteePeriod(Integer guaranteePeriod) {
        this.guaranteePeriod = guaranteePeriod;
    }

    public Date getProduceDate() {
        return produceDate;
    }

    public void setProduceDate(Date produceDate) {
        this.produceDate = produceDate;
    }
}